<include file="../Public/header" />
<script data-main="__PUBLIC__/admin/js/page/admin/content/attach" src="__PUBLIC__/admin/js/lib/requirejs/require.js"></script>
</head>

<body>

  <div class="page">
    <div class="page-hd">
      <h1>{$Think.lang.attachManage}</h1>
    </div>
    <div class="filterbar">
      <form id="search" method="post">
        <input id="recycle" class="input-text" name="recycle" type="hidden" value="{$recycle}">
        <label for="id">ID</label>
        <input type="number" name="id" id="id" value="{$id}" class="input-text">
        <label for="userId">{$Think.lang.userId}</label>
        <input type="number" name="userId" id="userId" value="{$userId}" class="input-text">
        <label for="">{$Think.lang.extension}</label>
        <select id="extension" name="extension">
          <option value="" selected>-</option>
          <volist name="extensions" id="vo">
            <option value="{$vo}" <php>if($vo==$extension) echo 'selected';</php>
              >{$vo}
            </option>
          </volist>
        </select>
        <button type="submit" class="btn-search" id="J_search" title="搜索">
          <i class="icon-search"></i>
        </button>
      </form>
    </div>
    <!-- <div class="section-hd">
        <h3 class="section-ti">{$Think.lang.attachManage}</h3>
      </div> -->
    <div class="datas">
      <div class="datas-bd">
        <table class="table">
          <thead>
            <tr>
              <th style="width: 10px;">
                <input type="checkbox" class="toggle-all" />
              </th>
              <th style="">ID</th>
              <th style="">UID</th>
              <th style="">{$Think.lang.uname}</th>
              <th style="">{$Think.lang.attachType}</th>
              <th style="">{$Think.lang.attachName}</th>
              <th style="">{$Think.lang.attachSize}</th>
              <th style="">{$Think.lang.extension}</th>
              <th style="">{$Think.lang.uploadTime}</th>
              <th style="">{$Think.lang.savepath}</th>
              <th style="">{$Think.lang.operating}</th>
            </tr>
          </thead>
          <tbody>
            <volist id="vo" name="list">
              <tr overstyle='on' data-id="{$vo['id']}">
                <td>
                  <input type="checkbox" class="toggle" />
                </td>
                <td>{$vo.id}</td>
                <td>{$vo.userId}</td>
                <td>{$vo.userId}</td>
                <td>{$vo.attach_type}</td>
                <td><a href="{$rootPath}{$vo.savepath}{$vo.savename}" target="_blank">{$vo.name}</a>
                </td>
                <php>$vo['size'] = round($vo['size']/1000,2);</php>
                <td>{$vo.size} K</td>
                <td>{$vo.extension}</td>
                <td>{$vo.uploadTime|date="Y-m-d H:i",###}</td>
                <td>{$vo.savepath}{$vo.savename}</td>
                <td><a href="javascript:;" class="A_deleteRecord">{$Think.lang.delRecords}</a>
                  | <a href="javascript:;" class="A_deleteFile">{$Think.lang.delRecordsAndFile}</a>
                </td>
              </tr>
            </volist>
          </tbody>
        </table>
      </div>
    </div>
    <div class="datas-ft">
      <div class="pager">{$page}</div>
      <div class="actions">
        <a href="javascript:;" class="btn" id="J_deleteRecord">{$Think.lang.delRecords}</a>
        <a href="javascript:;" class="btn" id="J_deleteFile">{$Think.lang.delRecordsAndFile}</a>
      </div>
    </div>
  </div>
  </div>
</body>

</html>
